<template>
  <Submenu :name="showName(item)">
    <template slot="title">
      <common-icon :size="iconSize" :color="iconColor" :type="item.icon" />
      <span>{{ showTitle(item) }}</span>
    </template>
    <template v-for="(child,index) in item.children">
      <default-menu-sub v-if="showChildren(child)" :key="index" :item="child" />
      <default-menu-item v-else :item="child" :key="index" />
    </template>
  </Submenu>
</template>
<script>
import mixin from "./mixin";
import DefaultMenuItem from "./default-menu-item";
export default {
  components: { DefaultMenuItem },
  mixins: [mixin]
};
</script>
